<!DOCTYPE html>
<!--[if IE 8]> <html lang="en" class="ie8 no-js"> <![endif]-->
<!--[if IE 9]> <html lang="en" class="ie9 no-js"> <![endif]-->
<!--[if !IE]><!-->
<html lang="en" class="no-js">
<!--<![endif]-->

<head>
<meta charset="utf-8">
<title>SMM·支付 管理系统</title>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta content="width=device-width, initial-scale=1" name="viewport">
<meta content="" name="description">
<meta content="" name="author">
<link href="${request.getContextPath()}/Public/assets/admin/css/css.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/plugins/font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/plugins/simple-line-icons/simple-line-icons.min.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/plugins/bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/plugins/uniform/css/uniform.default.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/css/components-rounded.css" id="style_components" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/css/plugins.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/admin/css/layout.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/admin/css/themes/default.css" rel="stylesheet" type="text/css" id="style_color">
<link href="${request.getContextPath()}/Public/assets/admin/css/custom.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/plugins/bootstrap-datepicker/css/bootstrap-datepicker.min.css" rel="stylesheet" type="text/css">
<link rel="stylesheet" type="text/css" href="${request.getContextPath()}/Public/assets/global/plugins/jquery-notific8/jquery.notific8.min.css" />
<link href="${request.getContextPath()}/Public/assets/admin/css/common.css" rel="stylesheet" type="text/css">
<link href="${request.getContextPath()}/Public/assets/global/css/kkpager.css" rel="stylesheet" type="text/css">
<link rel="shortcut icon" href="${request.getContextPath()}/Public/favicon.ico">
<script>
	BASE_URL = '${request.getContextPath()}'
</script>
<style type="text/css">

.table-condensed {
	width: 100%;
}

.datepicker-inline {
	width: 100%;
}

.col-md-4,.col-md-6,.col-md-7,.col-md-12 {
	padding-right: 0px;
	padding-left: 0px;
}
.table>tbody>tr>td, .table>tbody>tr>th, .table>tfoot>tr>td, .table>tfoot>tr>th, .table>thead>tr>td, .table>thead>tr>th {
  border-bottom: 1px solid #ddd;
}
</style>

</head>

<body class="page-header-top-fixed page-footer-fixed">
	
	<div class="page-header">
		<!--头部开始-->
		<#include "/include/top.html" />
		<!-- 头部信息结束 -->
	</div>
	
	<div class="clearfix">
	</div>
	<div class="page-container">
		<#include "/include/menu.html" />
		<!-- 首页内容开始 -->
		<div class="page-content-wrapper">
		<div class="page-content" >
			<div class="container-fluid">
				<div class="col-md-12" style="margin-top: 50px;">
					<div class="row">
						<div class="col-md-12">
							<div class="portlet light">
									<div class="portlet-body">
											<div class="row" style="height: 56px; text-align:left ;">
												<div class="col-sm-12">
													<div id="sample_2_filter" class="dataTables_filter">
														<label>邮箱/用户名:
															<input type="search" class="form-control input-medium  input-inline" id="userNameM"   placeholder="邮箱/用户名" aria-controls="sample_2" >
														</label>
														&nbsp;	
														<label>企业名称：
															<input type="search" class="form-control input-medium  input-inline" id="companyName" placeholder="企业名称" aria-controls="sample_2" >
														</label>
														&nbsp;
														<label>手机号码:
															<input type="search" class="form-control input-medium  input-inline" id="mobilePhone" placeholder="手机号码" aria-controls="sample_2" >
														</label>
														&nbsp;
														<button  class="btn red"  type="button" onclick="selList();">
															<i class="fa fa-search"></i> 搜索 
														</button>
														<button  class="btn red"  type="button" onclick="removeVal();">
															<i class="fa fa-remove"></i> 取消 
														</button>
													</div>
												</div>
											</div>
											<table class="table table-striped table-bordered table-hover">
											<thead>
											<tr>
												<th>
													操作
												</th>
												<th>
													会员ID
												</th>
												<th>
													邮箱
												</th>
												<th>
													商城帐号
												</th>
												<th>
													公司名
												</th>
												<th>
													注册时间
												</th>
												<th>
													帐户余额
												</th>
												<th>
													可用余额
												</th>
											</tr>
											</thead>
											<tbody id="uList">
												
											</tbody>
										</table>
										<div style="text-align: center;margin-rigsht: 5%;">
											<button  class="btn red btn-lg"  type="button" onclick="doClick();">
												&nbsp;&nbsp;确定出金&nbsp;&nbsp;
											</button>
										</div>
									</div>
								</div>
							</div>
						</div>	
					</div>
				</div>
			</div>
		</div>
		<!-- END PAGE CONTENT -->
	</div>
	<!-- END PAGE CONTAINER -->
	<!-- 底部开始 -->

	<!-- 底部结束 -->

	<!--[if lt IE 9]>
<script src="${request.getContextPath()}/Public/assets/global/plugins/respond.min.js"></script>
<script src="${request.getContextPath()}/Public/assets/global/plugins/excanvas.min.js"></script>
<![endif]-->
	<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery.min.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery-migrate.min.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery-ui/jquery-ui.min.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/bootstrap/js/bootstrap.min.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/bootstrap-hover-dropdown/bootstrap-hover-dropdown.min.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery-slimscroll/jquery.slimscroll.min.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery.blockui.min.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery.cokie.min.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/uniform/jquery.uniform.min.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery-notific8/jquery.notific8.min.js"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/jquery.sparkline.min.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/bootstrap-datepicker/js/bootstrap-datepicker-index.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/scripts/metronic.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/admin/scripts/layout.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/admin/scripts/commonUtils.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/highcharts.js" type="text/javascript"></script>
	<script src="${request.getContextPath()}/Public/assets/global/plugins/kkpager.min.js" type="text/javascript"></script>
	<script type="text/javascript" src="${request.getContextPath()}/Public/My97DatePicker/WdatePicker.js"></script>
	<script>
		jQuery(document).ready(function() {

			Metronic.init(); // init metronic core componets
			Layout.init(); // init layout
			//IndexComponent.init(); // init index component
		});


		
		function doClick(){
	 		var userId=$('input[name="userId"]:checked').val();
	 		var userCompanyName=$('input[name="userId"]:checked').attr("companyName");
	 		if(userId==null){
	 			CommonUtils.succModal('系统提示','请选择需要出金的会员！');
	 			return;
	 		}
			var url="${request.getContextPath()}/UserAccount/goDebitsPage.do?userId="+userId+"&userCompanyName="+userCompanyName;
			CommonUtils.editModal(url,800);
		}
		//页面搜索区域
		function selList(){  
			var userName= $('#userNameM').val();
			var companyName= $('#companyName').val();
			var mobilePhone= $('#mobilePhone').val();
			//后台提交
			$.ajax({
		    		type: "POST",
		    		url: BASE_URL+"/UserAccount/getDebitsList.do",
		    		data:{"userName":userName,"companyName":companyName,"mobilePhone":mobilePhone},
		    		dataType: "json",
		    		success: function(res){
		    			if(res.code=="succ"){
		    				if(res.user !=null){
		    					$('#userNameM').val(res.user.userName);
		    					$('#companyName').val(res.user.companyName);
		    					$('#mobilePhone').val(res.user.mobilePhone);
		    				}
		    				var tmp="";
		    				for(var UserAccountEntity in res.ulist){
		    					if(res.ulist[UserAccountEntity].mallUserName ==null){
		    						res.ulist[UserAccountEntity].mallUserName="";
		    					}
		    					if(res.ulist[UserAccountEntity].companyName ==null){
		    						res.ulist[UserAccountEntity].companyName="";
		    					}
		    					if(res.ulist[UserAccountEntity].registerTime ==null){
		    						res.ulist[UserAccountEntity].registerTime="";
		    					}
		    					if(res.ulist[UserAccountEntity].countMoney ==null){
		    						res.ulist[UserAccountEntity].countMoney="";
		    					}
		    					if(res.ulist[UserAccountEntity].useMoney ==null){
		    						res.ulist[UserAccountEntity].useMoney="";
		    					}
		    				 	tmp=tmp+"<tr>"+
		    						"<td><input type='radio' name='userId' id='userId' value='"+res.ulist[UserAccountEntity].userId+"' companyName='"+res.ulist[UserAccountEntity].companyName+"'></td>"+
									"<td>"+res.ulist[UserAccountEntity].userId+"</td>"+
									"<td>"+res.ulist[UserAccountEntity].userName+"</td>"+
									"<td>"+res.ulist[UserAccountEntity].mallUserName+"</td>"+
									"<td>"+res.ulist[UserAccountEntity].companyName+"</td>"+
									"<td>"+res.ulist[UserAccountEntity].registerTime+"</td>"+
									"<td>"+res.ulist[UserAccountEntity].countMoney+"</td>"+
									"<td>"+res.ulist[UserAccountEntity].useMoney+"</td>"+
									"</tr>";
		    				}
		    				$("#uList").empty();
		    				$("#uList").append(tmp);
		    			}
		    			else {
		    				CommonUtils.succModal('系统提示','搜索结果过多，请更换搜索条件！');
		    			}
		    		}
		   });
		}
		
		//清除页面搜索区域
		function removeVal(){
			$('#userNameM').val("");
			$('#companyName').val("");
			$('#mobilePhone').val("");
		}

	</script>
</body>
</html>